package com.voja.workoutrandomizer.repository;

import java.util.ArrayList;

import org.json.JSONException;
import org.json.JSONObject;

public class Workout {
	
	private ArrayList<Exercise> exercises;
	private JSONObject definition;
	
	private String title = "";
	
	public Workout(JSONObject definition) {
		this.definition = definition;
		
		try {
			title = definition.getString("title");
		} catch (JSONException e) {
			
		}
	}
	
	public void addExercise(Exercise exercise) {
		exercises.add(exercise);
	}
	
	public String getTitle() {
		return this.title;
	}
	
	public JSONObject getDefinition() {
		return definition;
	}

}
